-
Notifications
You must be signed in to change notification settings - Fork 41
Ephemeral room support #367
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR implements ephemeral room support by removing legacy tutorial room copies and updating the room configuration. Key changes include the removal of multiple tutorial room scripts, the introduction of delay parameters for tutorial commands, and an updated configuration file (config.yaml) with a new TutorialStartRooms array for ephemerally instantiated rooms.
Reviewed Changes
Copilot reviewed 98 out of 106 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| _datafiles/world/default/rooms/tutorial/*.js | Removal or update of legacy tutorial scripts with delay updates |
| _datafiles/config.yaml | Updated TutorialStartRooms configuration to support ephemeral rooms |
Files not reviewed (8)
- Makefile: Language not supported
- _datafiles/world/default/rooms/tutorial/910.yaml: Language not supported
- _datafiles/world/default/rooms/tutorial/911.yaml: Language not supported
- _datafiles/world/default/rooms/tutorial/912.yaml: Language not supported
- _datafiles/world/default/rooms/tutorial/913.yaml: Language not supported
- _datafiles/world/default/rooms/tutorial/920.yaml: Language not supported
- _datafiles/world/default/rooms/tutorial/921.yaml: Language not supported
- _datafiles/world/default/rooms/tutorial/922.yaml: Language not supported
Comments suppressed due to low confidence (1)
_datafiles/world/default/rooms/tutorial/913.js:30
- Correct the typo in the message from 'I\ll' to 'I'll' to improve clarity.
teacherMob.Command('say I\ll summon a portal to send you to the heart of Frostfang city, where your adventure begins.', extraDelay+2.0);
|
Outside of a few comments it looks good, large change and I did not get to test it. Could use some unit tests as well. |
| // Also sends music changes out | ||
| // | ||
|
|
||
| const guideMobId = 38 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this move to a config?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think it'll be a module soon, and then we can customize that.
| connections.Remove(connId) | ||
|
|
||
| testRoomId := rooms.GetOriginalRoom(user.Character.RoomId) | ||
| if testRoomId >= 900 && testRoomId <= 999 { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should this move to a config?
internal/usercommands/admin.room.go
Outdated
| } | ||
|
|
||
| if room == nil { | ||
| user.SendText(`Something went wrong for RoomId: ` + strconv.Itoa(liveRoom.RoomId)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this also be a log message?
Description
This adds support for Ephemeral rooms.
Ephemeral rooms are instances of rooms that are unique and get their own RoomId's. They cannot be saved to disk, and are cleaned up when all players leave the group of instanced/ephemeral rooms.
This is accomplished by allocating a range of RoomId's that are used only by ephemeral ID's. Room's being copied get their RoomId replaced with a newly generated one.
Changes
TutorialStartRoomsis now a complete list of all tutorial rooms, starting with the "tutorial start" room.rooms/ephemeral.gohandles ephemeral room specifics.